package com.zhanghs.ribonconfig;

import com.netflix.loadbalancer.IRule;
import com.netflix.loadbalancer.RandomRule;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

/**
 * ribbon 负载均衡规则
 * @Author zhanghongshan
 * @date 2021/9/13 9:40 下午
 */
@Configuration
public class RibonConfig {
    @Bean
    public IRule iRule(){
        return  new RandomRule();
    }
}
